<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>
<body>
  <script>
    let t=+prompt('请输入一个时间')
    function fn(t){
      let h=parseInt(t/60/60)
      let m=parseInt(t/60%60)
      let s=parseInt(t%60)
      h=h<10?'0'+h:h
      m=m<10?'0'+m:m
      s=s<10?'0'+s:s
      return `${h}:${m}:${s}`
    }
    let res=fn(t)
    document.write('转换后的时间是：'+res)
  </script>
  
    
  </script>
  
</body>
</html>